from simplebrain import *
import numpy as np

def f(x):
    return 10-x**2

def eval(think):
    fitness=float(-sum(list(map(
        lambda x:(f(x)-think([x]))**2,list(np.linspace(-3,3,5))
    ))))
    return fitness

if __name__=='__main__':
    retrain(eval,1000,ran_seeds_data())